﻿<Window x:Class="FM.时钟.Views.主窗口"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:models="clr-namespace:FM.时钟.Models"
        Title="时钟"
        Width="300"
        Height="300"
        AllowsTransparency="True"
        Background="#00000000"
        MouseDown="Window_MouseDown"
        SizeToContent="WidthAndHeight"
        WindowStyle="None" KeyDown="Window_KeyDown"   KeyUp="Window_KeyUp" ShowInTaskbar="False">
    <Window.ContextMenu>

        <ContextMenu FontSize="24">
            <MenuItem Margin="3"
                      Command="{Binding 置顶}"
                      Header="切换置顶"    />
            <MenuItem Margin="3"
                      Command="{Binding 修改}"
                      Header="修改" />
            <MenuItem Margin="3"
                      Command="{Binding 保存}"
                      Header="保存" />
            <MenuItem Margin="3"
                      Command="{Binding 退出}"
                      Header="退出" />
        </ContextMenu>

    </Window.ContextMenu>
    <Grid>
        <ItemsControl 
                      Background="{x:Null}"
                      ItemsSource="{Binding 数据列表}">
            <ItemsControl.ItemTemplate>
                <DataTemplate DataType="models:数据">
                    <TextBlock Margin="2" MouseWheel="Window_MouseWheel"
                               HorizontalAlignment="Center"
                               VerticalAlignment="Center"
                               Background="#01000000"
                               FontSize="{Binding 字体大小}"
                               Foreground="{Binding 字体颜色}"
                               FontFamily="{Binding 字体名称}"
                               Text="{Binding 显示文字}" />
                </DataTemplate>
            </ItemsControl.ItemTemplate>
        </ItemsControl>
    </Grid>

    <!--
        <Grid>
        <ListBox Name="list"
        Background="#00000000"
        BorderBrush="{x:Null}"
        ItemsSource="{Binding 数据列表}">
        <ListBox.ItemTemplate>
        <DataTemplate DataType="models:数据">
        <TextBlock Margin="2"
        HorizontalAlignment="Center"
        VerticalAlignment="Center"
        Background="#01000000"
        FontSize="{Binding 字体大小}"
        Foreground="{Binding 字体颜色}"
        Text="{Binding 显示文字}" />
        </DataTemplate>
        </ListBox.ItemTemplate>
        </ListBox>
        </Grid>
    -->
</Window>


